package com.tedu.lingmaagent.domain;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.bson.types.ObjectId;
import org.springframework.data.annotation.Id;
import org.springframework.data.mongodb.core.mapping.Document;

/*@Setter
@Getter*/
@Data
@AllArgsConstructor
@NoArgsConstructor
@Document("chat_messages")//mongodb数据的表 文档表
public class ChatMessages {
    //文档中的key
    @Id
    private ObjectId messageId;
    //用户提供的id
    private int memoryId;

    private String content;//存储当前文档

    public void setContent(String content) {
        this.content = content;
    }

    public String getContent() {
        return this.content; // 假设 content 是存储消息内容的字段
    }

}
